<?php
global $user;
if(empty($user)) tr_redirect(get_option('siteurl'));

$xajax = new xajax(); 
//$xajax->debugOn(); // Uncomment this line to turn debugging on
$xajax->registerFunction("logoutFunc");

$xajax->registerFunction("processFavorit");
$xajax->registerFunction("unfavoritFunc");
$xajax->registerFunction("reportProblem");
$xajax->registerFunction("hidePost");

$xajax->processRequests();
?>

<?php get_header(); ?>

<DIV id=container><br/>

<DIV id=sub-nav>
<UL>
  <LI><A href="<?=get_option('siteurl')?>">首页</A> </LI>
  <LI class=active><SPAN>文章收藏</SPAN> </LI>
  <LI><A href="./?user=<?php the_user_name(); ?>&profile">个人资料</A> </LI>
  </UL><BR></DIV>

<DIV id=sub-nav-2>
<UL>
  <LI><?php subnav2_userhome_text();?></LI>
  <LI><?php subnav2_usersubmitted_text();?></LI>
  <LI><?php subnav2_usercommented_text();?></LI>
</UL><BR /></DIV>

<DIV id=contents2>

	<?php if (have_posts()) : while (have_posts()) : the_post(); ?>	

<DIV class=news-summary id=news-<?php the_post_id(); ?> style="Z-INDEX: <?php get_z_index(); ?>;">
<DIV class=news-body>
<H4 id=title<?php the_post_id(); ?>><A href="<?php the_post_url(); ?>" target="_blank"><?php the_post_title(); ?></A> </H4>
<P class=news-submitted><A href="<?php the_siteurl(); ?>/?user=<?php the_post_author(); ?>"><?php the_post_author(); ?></A> 于 <?php the_past_time(); ?> 前提交 <span class=viaurl><?php get_viaurls(); ?></span><?php edit_post_link("[编辑]","<SPAN class=tool>","</SPAN>"); ?></P>

<?php get_popup_urls(); ?>

<DIV class=news-details>
<A class="tool comments" href="<?php the_siteurl(); ?>/?q=<?php the_post_id(); ?>"><?php get_comment_text(); ?></A>
<SPAN class=tool>标签:<?php get_post_tags_5(); ?> </SPAN>

<?php unfavorit_link(); ?>
<?php hide_post_link("隐藏","<SPAN class=tool>","</SPAN>"); ?>
<?php promote_post_link(); ?>

<?php if(get_currentuserinfo()): ?>
<ul class="probdrop" id="ul<?php the_post_id(); ?>" style="z-index:<?php get_z_index(); ?>;">
<li><a href="javascript://" onclick="HideandUNhideObj('<?php the_post_id(); ?>');" class="toplinep">问题反馈</a>
<div style="display: none;" id="div<?php the_post_id(); ?>">
 <ul>
      <li class="probdroplist"><a href="javascript://" onclick="javascript:xajax_reportProblem(<?php the_post_id(); ?>,<?php get_currentuserid(); ?>,1); HideandUNhideObj(<?php the_post_id(); ?>)" class="droplinep">重复的文章</a></li>
      <li class="probdroplist"><a href="javascript://" onclick="javascript:xajax_reportProblem(<?php the_post_id(); ?>,<?php get_currentuserid(); ?>,2); HideandUNhideObj(<?php the_post_id(); ?>)" class="droplinep">链接无法访问</a></li>
      <li class="probdroplist"><a href="javascript://" onclick="javascript:xajax_reportProblem(<?php the_post_id(); ?>,<?php get_currentuserid(); ?>,3); HideandUNhideObj(<?php the_post_id(); ?>)" class="droplinep">垃圾信息</a></li>
      <li class="probdroplist"><a href="javascript://" onclick="javascript:xajax_reportProblem(<?php the_post_id(); ?>,<?php get_currentuserid(); ?>,4); HideandUNhideObj(<?php the_post_id(); ?>)" class="droplinep">内容不准确</a></li>
</ul>
</div>
</li>
</ul>
<?php endif; ?>

</DIV></DIV>

<UL class=news-digg-s>
  <LI class="digg-count-s shade-s-<?php the_shade_id(); ?>" id=main0>
  <A id=diggs<?php the_post_id(); ?> href="<?php the_siteurl(); ?>/?q=<?php the_post_id(); ?>"><STRONG id=diggs-strong-<?php the_post_id(); ?>><?php the_favor_count(); ?></STRONG></A> 
  <LI class=digg-it-s id=diglink<?php the_post_id(); ?>><?php get_favorit_link(); ?>
  </LI>
</UL>

</DIV>

	<?php endwhile; else: ?>
		<?php if(is_user_submitted()&&(the_user_id(false)==get_currentuserid(false))): ?>
		<br/>你还没有提交过文章，请点击<A HREF="./?submit">这里</A>提交新的文章。
		<?php endif; ?>
	<?php endif; ?>
    
  
<div class="pages">
<?php get_post_nav(); ?>
</div>

</DIV>

<DIV id=sidebar2>

<UL class=main-menu>

  <LI>
  <DIV class=boxed>
  <DIV><SPAN>文章标签分类</SPAN> 
  <ul class="category-list">
  <?php get_place_list(); ?>
  
  </ul>
<br /></DIV></DIV>
  
  <!-- <li>
	<div class="boxed">
	<div>
	<span><label for="search">搜索文章</label></span>
	<form action="/diggall" method="post">
	<input type="text" id="search" name="search" value=""/>
	<INPUT class=sbutton onclick=searchboxClick(); type=image alt=Search src="<?php bloginfo('stylesheet_directory'); ?>/img/important-search.gif" name=submit>
	</form>
	</div>
	</div>

<LI><A href="./?feed" class="rss">该用户收藏文章聚合<img src="<?php bloginfo('stylesheet_directory'); ?>/img/rss.gif" border=0 align=absmiddle></A> -->
</UL></DIV></DIV>
</DIV></DIV>
  
<?php get_footer(); ?>

